    	<div class="position">当前位置：<a href="<?php echo Yii::app()->createUrl('member/index/index');?>"><?php echo t('Member','web') ?></a> &gt; <a href="<?php echo Yii::app()->createUrl('member/index/refund');?>">客户服务</a> &gt; 售后管理</div>
        <div class="hr_15"></div>
		<div class="steps">
            <ul class="fs_14 c_f">
                <li class="cur first"><span class="one">第一步,买家申请退款</span></li>
                <li class=""><span class="two">第二步，卖家处理退款申请</span></li>
                <li class="last"><span class="three">第三步，退款成功</span></li> 
            </ul>
        </div>
        <div class="hr_20"></div>
        <!--售后管理 start-->
        <div class="aftersales_box pub_tab min_pub_tab" id="refundTab">
        	<div class="tab_hd2 c_f">
                <ul class="f_l">
                    <li><a href="javascript:">我要退货</a></li>
                    <li><a href="javascript:">我要退款(无需退货)</a></li>
                </ul>
            </div>
            <div class="step_box">
                <!--申请售后  start-->
                <div class="step_info">
                    <div class="tab_cont2">
                        <?php 
                            $form = $this->beginWidget('CActiveForm', 
                            array(
                            'id'=>'user-form',
                            'action'=>Yii::app()->createUrl('member/index/aftersaletwo'),	
                            'enableAjaxValidation'=>false,
                            'enableClientValidation'=>true,	
                            'clientOptions'=>array( 
                                'id'=>'addressFrm',
                            ),
                            )); ?>
                            <?php echo $form->hiddenField($model,'zop_id',array('value'=>Yii::app()->request->getParam('ordproductid'))); ?>
                            <?php echo $form->hiddenField($model,'zr_return',array('value'=>2)); ?>
                            <ul class="form_list">
                                <li>
                                <span class="tit"><em class="xing">*</em>需退款金额：</span>
                                <?php echo $form->textField($model,'zr_amount',array('class'=>'t_ipt','value'=>'','style'=>'height:15px; width:60px;','maxlength'=>'10')); ?>
                                <span>最多<em class="c_f60"><?php echo $model->zr_amount; ?></em>元</span>
                                </li>
                                <li><span class="tit"><em class="xing">*</em>退款原因：</span>
                                <?php echo $form->dropDownList($model,'zr_reason',$this->refundReason,array('class'=>'s_ipt','id'=>'changeLevel')); ?>
                                </li>
                                <li class="c_f"><span class="tit f_l">上传凭证：</span>
                                    <div class="cert_img f_l">
                                        <p class="c_999"><span class="ico ico_tip"></span>每张图片大小不能超过500K</p>
                                        <ul class="uploadimg c_f">
                                            <li>
                                                <img id="img11" src="/images/cert_img.jpg" alt="" />
                                                <button id="upbutton1" onclick="file1.click();return false;" class="mem_btn mem_btn10">上传...</button>
                                                <input id="file1" class="d_n" type="file" onclick="uploadimg(1)" value="" name="image" />
                                                <input id="pic1" type="hidden" value="" name="images[]" />
                                            </li>
                                            <li>
                                                <img id="img22" src="/images/cert_img.jpg" alt="" />
                                                <button id="upbutton2" onclick="file2.click();return false;" class="mem_btn mem_btn10">上传...</button>
                                                <input id="file2" class="d_n" type="file" onclick="uploadimg(2)" value="" name="image" />
                                                <input id="pic2" type="hidden" value="" name="images[]" />
                                            </li>
                                            <li>
                                                <img id="img33" src="/images/cert_img.jpg" alt="" />
                                                <button id="upbutton3;return false;" onclick="file3.click()" class="mem_btn mem_btn10">上传...</button>
                                                <input id="file3" class="d_n" type="file" onclick="uploadimg(3)" value="" name="image" />
                                                <input id="pic3" type="hidden" value="" name="images[]" />
                                            </li>
                                        </ul>
                                    </div>
                                </li>
                                <li><span class="tit">退款说明：</span>
                                    <?php echo $form->textArea($model,'zr_content',array('class'=>'t_area')); ?>
                                </li>                          
                                <li class="link"><span class="tit"></span><input class="mem_btn mem_btn05" type="submit" name="" value="申请退款" /><input class="mem_btn mem_btn08" type="button" name="" value="取消申请" /></li>
                            </ul>
                        <?php $this->endWidget(); ?>
                    </div>
                    <div class="tab_cont2">
                        <?php 
                            $form = $this->beginWidget('CActiveForm', 
                            array(
                            'id'=>'user-form',
                            'action'=>Yii::app()->createUrl('member/index/refundtwo'),	
                            'enableAjaxValidation'=>false,
                            'enableClientValidation'=>true,	
                            'clientOptions'=>array( 
                                'id'=>'addressFrm',
                            ),
                            )); ?>
                            <?php echo $form->hiddenField($model,'zop_id',array('value'=>Yii::app()->request->getParam('ordproductid'))); ?>
                            <?php echo $form->hiddenField($model,'zr_return',array('value'=>1)); ?>
                            <ul class="form_list">
                                <li>
                                <span class="tit"><em class="xing">*</em>需退款金额：</span>
                                <?php echo $form->textField($model,'zr_amount',array('class'=>'t_ipt','value'=>'','style'=>'height:15px; width:60px;','maxlength'=>'10')); ?>
                                <span>最多<em class="c_f60"><?php echo $model->zr_amount; ?></em>元</span>
                                </li>
                                <li><span class="tit"><em class="xing">*</em>退款原因：</span>
                                <?php echo $form->dropDownList($model,'zr_reason',$this->refundReason,array('class'=>'s_ipt','id'=>'changeLevel')); ?>
                                </li>
                                <li class="c_f"><span class="tit f_l">上传凭证：</span>
                                    <div class="cert_img f_l">
                                        <p class="c_999"><span class="ico ico_tip"></span>每张图片大小不能超过500K</p>
                                    <ul class="uploadimg c_f">
                                    	<li>
                                        	<img id="img44" src="/images/cert_img.jpg" alt="" />
                                            <button id="upbutton4" onclick="file4.click();return false;" class="mem_btn mem_btn10">上传...</button>
                                            <input id="file4" class="d_n" type="file" onclick="uploadimg(4)" value="" name="image" />
                                            <input id="pic4" type="hidden" value="" name="images[]" />
                                        </li>
                                    	<li>
                                        	<img id="img55" src="/images/cert_img.jpg" alt="" />
                                            <button id="upbutton5" onclick="file5.click();return false;" class="mem_btn mem_btn10">上传...</button>
                                            <input id="file5" class="d_n" type="file" onclick="uploadimg(5)" value="" name="image" />
                                            <input id="pic5" type="hidden" value="" name="images[]" />
                                        </li>
                                    	<li>
                                        	<img id="img66" src="/images/cert_img.jpg" alt="" />
                                            <button id="upbutton6" onclick="file6.click();return false;" class="mem_btn mem_btn10">上传...</button>
                                            <input id="file6" class="d_n" type="file" onclick="uploadimg(6)" value="" name="image" />
                                            <input id="pic6" type="hidden" value="" name="images[]" />
                                        </li>
                                    </ul>
                                    </div>
                                </li>
                                <li><span class="tit">退款说明：</span>
                                    <?php echo $form->textArea($model,'zr_content',array('class'=>'t_area')); ?>
                                </li>                          
                                <li class="link"><span class="tit"></span><input class="mem_btn mem_btn05" type="submit" name="" value="申请退款" /><input class="mem_btn mem_btn08" type="button" name="" value="取消申请" /></li>
                            </ul>
                        <?php $this->endWidget(); ?>
                    </div>
                </div>
                <!--申请售后  end -->
                <table class="list_table" cellpadding="0" cellspacing="0" width="100%">
            	<tr>
                	<th width="35%">宝贝信息</th>
                    <!-- <th width="15%">卖家</th> -->
                    <th width="12%">单价（元）</th>
                    <th width="12%">数量</th>
                    <th width="14%">优惠</th>
                    <th width="12%">小计（元）</th>
                </tr>
                <tr>
                	<td class="pro tl">
                    	<div class="c_img c_img50"><a href="<?php echo Yii::app()->createUrl('home/product/detail',array('id'=>$product['zp_id']));?>" title="" target="_blank"><img width="50" height="50" src="<?php echo $product->zp_pic; ?>" alt="" /></a></div>
                   		<p class="title_pro"><a class="c_06c" href="<?php echo Yii::app()->createUrl('home/product/detail',array('id'=>$product['zp_id']));?>" title="<?php echo $product['zp_name'];?>" target="_blank"><?php echo $product['zp_name'];?></a></p>
                    </td>
                    <!-- <td><a class="c_06c" href="<?php //echo Company::createCompanyUrl($product->company->zc_sub_domain);?>" title=""><?php //echo $product->company->zc_name;?></a></td> -->
                    <td><?php echo $ordproduct->zop_real_price;?></td>
                    <td><?php echo $ordproduct->zop_nums;?></td>
                    <td>
                    	<?php 
							foreach($discount as $key=>$value){
								echo OrdDiscount::getDiscountType($value->zod_type).'：-'.$value->zod_price.'</br>';
							}
						?>
                    </td>
                    <td><span class="fw_b fs_14 c_f60"><?php echo $ordproduct->zop_real_price*$ordproduct->zop_nums;?></span></td>
                </tr>
            </table>
            </div>
        </div>    
    	<!--售后管理 end-->
<script src='<?php echo Yii::app()->baseUrl;?>/js/jquery.ui.widget.js'></script> 
<script src='<?php echo Yii::app()->baseUrl;?>/js/jquery.iframe-transport.js'></script> 
<script src='<?php echo Yii::app()->baseUrl;?>/js/jquery.fileupload.js'></script> 
<script type="text/javascript">
       function uploadimg (id) {
        	   $('#file'+id).fileupload({         	
      		        dataType: 'json',       
      		        url: '/Attachment/GetAjax',        
      		        success: function (json) {
      		               if(json.upfile.errors=='1'){
      		               		alert(json.upfile.msg);
      		               }else if(json.upfile.errors=='2'){
      		               		alert(json.upfile.msg);
      		               }else{
          		                 //修改按钮图标
        		            	 $('#img'+id+id).attr('src',json.upfile.file);
								 //修改按钮文本
        		            	 $('#upbutton'+id).text('修改图片');
								 //修改隐藏域值
      		               		 $('#pic'+id).attr('value',json.upfile.file);
      		               } 	
      		        }
      		    });
		};				
 </script>